-
Notifications
You must be signed in to change notification settings - Fork 52
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
typedefs generation #229
typedefs generation #229
Conversation
I don't see this change in the PR? It's still type TextureID struct {
Data unsafe.Pointer
} which is very inconvenient to work with |
yep, it is unsafe.Pointer but I thnk to make it |
I remember I choose unsafe.Pointer for a reason, like race tracing issue. |
Yeah but this makes my feel a bit crazy.. golang/go#64111 |
Yeah, that would work, right now I'm using something like this ptr := unsafe.Pointer(uintptr(b.Tex.GetRef()))
ImageV(TextureID{Data: ptr}, // ... |
How would that work? 🤔 |
changed to uintptr. If it compiles with -race I can merge this PR |
well it doesn't compile unfortunately...
We can either use uintptr and fail each |
generally I'm to lazy to write unittests, but in this particular case it is useful to state whether my regex works and to ensure that it will not crash in future
implement opaque structs and alias types
currently it applies to cimgui functions and typedefs. What is missing is the struct_accessor that will be reworked in the next commit. Rason for that is golang/go#64467
@gucio321 awesome! Your PR fixed not only font builder, but also clipper too. Thx a lot! |
Great to hear this! I deffinitely need to finish this and merge to master! |
its mostly done, now I'm getting "works for me" issue. |
…es this fact was skipped)
I pushed some fixes. I hope this will work soon. |
0 is more appropiate null value for uintptr_t
this file is deprecated and was replaced by gengo_typedefs.go
@gucio321 Thanks for the effort! This PR took a while to get done, but it fixed all the problems I had workarounds for! |
This pull requests contains the following changes:
type TextureID uint32
)